package constants

import (
	"ch05/instructions/base"
	"ch05/rtda"
)

type BIPUSH struct {
	val int8
}

type SIPUSH struct {
	val int16
}


func (self *BIPUSH) FetchOperands(reader *base.BytecodeReader) {
	self.val = reader.ReadInt8()
}

func (self *BIPUSH) Execute(frame rtda.Frame) {
	i:=int32(self.val)
	frame.OperandStack().PushInt(i)
}